#pragma once
#include <cocos2d.h>

USING_NS_CC;

class LevelData : public CCObject
{
public:
	inline LevelData(void)
	{
		_id = 0;
		_endExp = 0;
	}
	inline ~LevelData(void)
	{
	}

	CC_SYNTHESIZE(int, _id, Id);
	CC_SYNTHESIZE(int, _endExp, EndExp);
};

class PlayerData : public CCObject
{
public:
	inline PlayerData()
	{
		_planeId = NULL;
		_planeLevel = 1;
		_petType = NULL;
		_petWeapon = 1;
	}

	inline ~PlayerData()
	{
		CC_SAFE_RELEASE(_planeId);
		CC_SAFE_RELEASE(_petType);
	}

	CC_SYNTHESIZE(int, _gold, Gold);
	CC_SYNTHESIZE(int, _userExp, UserExp);
	CC_SYNTHESIZE_RETAIN(CCString*, _planeId, PlaneId);
	CC_SYNTHESIZE(int, _planeLevel, PlaneLevel);
	CC_SYNTHESIZE_RETAIN(CCString*, _petType, PetType);
	CC_SYNTHESIZE(int, _petWeapon, PetWeapon);

};


class PlaneData : public CCObject
{
public:
	inline PlaneData()
	{
		_type = NULL;
		_weapon = NULL;
	}
	inline ~PlaneData()
	{
		CC_SAFE_RELEASE(_type);
		CC_SAFE_RELEASE(_weapon);
	}

	CC_SYNTHESIZE_RETAIN(CCString*, _type, Type);
	CC_SYNTHESIZE_RETAIN(CCString*, _weapon, Weapon);
	CC_SYNTHESIZE(int, _damage,	Damage);
	CC_SYNTHESIZE(int, _health,	Health);
	CC_SYNTHESIZE(int, _speed,	Speed);
	CC_SYNTHESIZE(int, _price, Price);
};
